//
//  ViewController.m
//  ocrcard
//
//  Created by jyh on 2018/5/17.
//  Copyright © 2018年 huig. All rights reserved.
//

#import "ViewController.h"
#import "YHScanCardViewController.h"
#import "CardModel.h"
@interface ViewController ()

@end

@implementation ViewController

- (void)viewDidLoad {
    [super viewDidLoad];
   
    self.view.backgroundColor = [UIColor whiteColor];
    self.navigationItem.title = @"身份证识别";
    
    UIButton *IdCardBtn = [[UIButton alloc]initWithFrame:CGRectMake(100 , 150, 100, 50)];
    IdCardBtn.backgroundColor = [UIColor lightGrayColor];
    [IdCardBtn addTarget:self action:@selector(btn:) forControlEvents:UIControlEventTouchUpInside];
    [IdCardBtn setTitle:@"身份证识别" forState:0];
    
    [self.view addSubview:IdCardBtn];
    
    UILabel *lab = [[UILabel alloc] initWithFrame:CGRectMake(100, 200, 200, 30)];

    lab.backgroundColor = [UIColor blueColor];
    lab.text = self.model.bankNumber;
    
    [self.view addSubview:lab];
    
    NSLog(@"%@",self.model);
}

- (IBAction)btn:(id)sender {
    
    YHScanCardViewController *vc = [YHScanCardViewController new];
    
    [self.navigationController pushViewController:vc animated:YES];
    
}


- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}


@end
